#import "DreamerSoarController.h"
        
#import "DreamerSoarModel.h"
#import "DreamerSoarCell.h"
#import "Masonry.h"

@interface DreamerSoarController () <UITableViewDataSource, UITableViewDelegate>

@property (nonatomic, strong) UITableView *imprintTableView;
@property (nonatomic, strong) NSMutableArray *breezeJeopardyArray;

@end

@implementation DreamerSoarController

- (void)viewWillAppear:(BOOL)animated {
    [super viewWillAppear:animated];
}

- (void)viewDidLoad {
    [super viewDidLoad];

    [self oasisSetuplayout];
	[self nostalgiaXenophileloadData];
}


//: 懒加载数据模型数组
- (NSMutableArray *)breezeJeopardyArray {
	if (!_breezeJeopardyArray) {
		_breezeJeopardyArray = [NSMutableArray array];
	}
	return _breezeJeopardyArray;
}

//: 初始化页面UI
- (void)oasisSetuplayout {

	[self.view addSubview:self.imprintTableView];
	[self.imprintTableView mas_makeConstraints:^(MASConstraintMaker *make) {
		make.leading.trailing.equalTo(self.view);
		make.top.equalTo(self.view);
		make.bottom.equalTo(self.view.mas_safeAreaLayoutGuideBottom);
	}];
}


- (UITableView *)figHandleTableView {
    if (!_imprintTableView) {
        _imprintTableView = [[UITableView alloc] initWithFrame:self.view.bounds style:UITableViewStylePlain];
        _imprintTableView.autoresizingMask = UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight;
        _imprintTableView.estimatedRowHeight = 0;
        _imprintTableView.separatorStyle = UITableViewCellSeparatorStyleNone;
        _imprintTableView.contentInset = UIEdgeInsetsMake(16, 0, 16, 0);
        _imprintTableView.delegate = self;
        _imprintTableView.dataSource = self;
        _imprintTableView.tableFooterView = [[UIView alloc] initWithFrame:CGRectZero];
        _imprintTableView.showsVerticalScrollIndicator = NO;
        _imprintTableView.showsHorizontalScrollIndicator = NO;
        _imprintTableView.backgroundColor = UIColor.clearColor;
    }
    return _imprintTableView;
}

//: 获取数据模型
- (void)nostalgiaXenophileloadData {
	
}

#pragma mark - UITableView DataSource 
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
    return self.breezeJeopardyArray.count;
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
    DreamerSoarCell *kineticDelightResilient = [tableView dequeueReusableCellWithIdentifier:NSStringFromClass([DreamerSoarCell class])];
    if (kineticDelightResilient == nil) {
        kineticDelightResilient = [[DreamerSoarCell alloc] initWithStyle:UITableViewCellStyleValue1 reuseIdentifier:NSStringFromClass([DreamerSoarCell class])];
    }
    kineticDelightResilient.selectionStyle = UITableViewCellSelectionStyleNone;
    
    return kineticDelightResilient;
}

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath {
	DreamerSoarModel *quenchSuspicionBalance = self.breezeJeopardyArray[indexPath.row];
	return quenchSuspicionBalance.perceptiveXeroxCellHeight;
}


#pragma mark - UITableView Delegate
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    // cell tap action
}


@end
